package com.treeroot.designMode.Strategy;

/**
 * 具体策略类 继承实现打折策略
 *
 * @author treeroot
 */
public class FullMinusStrategy implements DiscountStrategy {
    @Override
    public double calculateDiscountPrice(Goods goods) {
        if (goods.getPrice() >= 100) {
            return goods.getPrice() - 20;
        }
        return goods.getPrice();
    }
}
